#include <iostream>
#include "header.h"

int main(int argc, char ** argv) {
	try {
		Scenario *scen;
		scen = NULL;
		arguments = parse(argc, argv);
		setSeed(arguments.seed);
		if (arguments.p == PART1) {
			scen = &scen1;
		}
		else if (arguments.p == PART2) {
			switch (arguments.distribution) {
			case UNIF:
				scen = &scen2unif;
				break;
			case EXPO:
				scen = &scen2expo;
				break;
			case CONST:
				scen = &scen2const;
				break;
			}
		}
		scen->run();
		if (scen != NULL) {
			delete scen;
		}
	}
	catch (char const * e) {
		std::cerr << e << std::endl;
		return 1;
	}
}
